package com.sdk.auth.enums;

import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Getter;

@Getter
@AllArgsConstructor(access = AccessLevel.PRIVATE)
public enum ServerUrlEnum {

    TEST1("/test1/enc/"),
    TEST2("/test2/enc/"),
    TEST3("/test3/enc/");

    private String type;

    /**
     * 需要AES+RSA加解密的接口地址
     * @param url
     * @return
     */
    public static boolean check(String url){
        if(url.startsWith(TEST1.getType()) || url.startsWith(TEST2.getType()) || url.startsWith(TEST3.getType())){
            return true;
        }
        return false;
    }
}
